package main

import (
	"github.com/pkg/errors"
	"github.com/smallnest/rpcx/protocol"
	"golang.org/x/net/context"
	"log"
)

const authToken string = "67080fc75bb8ee4a168026e5b21bf6fc"

type Watcher int

// agent 提交主机信息获取配置信息
func (w *Watcher) GetInfo(ctx context.Context, info *action.ComputerInfo, result *action.ClientConfig) error{
	return nil
}

//接收处理agent传输的信息
func (w *Watcher) PutInfo(ctx context.Context,datainfo *models.DataInfo, result *int)error{
	return nil
}

func auth(cxt context.Context, req *protocol.Message, token string) error{
	if token == authToken{return nil}
	return errors.New("invalid token")
}

func init(){
	log.Println(models.Config)

}

func main() {


}
